<?php
header("Cache-Control:no-cache, must-revalidate");  
?>
<div class="col-sm-9 col-sm-offset-3 col-md-10 col-md-offset-2 main">
<table border="0">
<tr>
<td width="120px" height="80px"><b>图书条码</b></td>
<td><input type="text" class="form-control input-lg" style = "width:500px" id="bookCode"></td>
</tr>
<tr>
<td width="120px" height="80px"></td>
<td><input type="submit" class="btn btn-danger btn-lg" value="删除" id="del"></td>
</tr>
</table>
</div>
<script>
$("#del").click(function(){

	var bookCode = $("#bookCode").val();

	if(!bookCode){
		alert("请将表单填写完整 :)");
	}else{
		$.ajax({
			type: "POST",
			url: "../../controller/delController.php",
			data: {
				bookcode: bookCode
			},
			success: function(data){
				alert(data);
				
				$("#bookCode").val("");
			}
		})
	}
})
</script>